<?php

use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreatePartsTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('parts', function (Blueprint $table) {
            $table->increments('id');   //维修活动表
            $table->char('title', 32)->comment('标题');
            $table->integer('pid')->comment('图库id');
            $table->char('summary')->comment('简介');
            $table->integer('price')->comment('价格');
            $table->integer('spec')->comment('规格个数');
            $table->text('content')->comment('配件详情');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::drop('parts');
    }
}
